/* SPDX-License-Identifier: GPL-2.0 */
#ifndef _PERF_SYS_H
#define _PERF_SYS_H

#include <bpf/bpf.h>
#include <sys/syscall.h>

static inline int sys_perf_event_open(struct perf_event_attr *attr,
                                      pid_t pid, int cpu, int group_fd,
                                      unsigned long flags) {
    return syscall(__NR_perf_event_open, attr, pid, cpu, group_fd, flags);
}

static inline int sys_bpf(enum bpf_cmd cmd, union bpf_attr *attr,
                          unsigned int size) {
    return syscall(__NR_bpf, cmd, attr, size);
}

#endif /* _PERF_SYS_H */
